package collection;

import java.util.ArrayList;
import java.util.Collection;
import java.util.Iterator;

public class Generic {
    public static void main(String[] args) {
        Collection<String>a=new ArrayList<>();
        a.add("444");
        a.add("414");
        a.add("244");
        a.add("443");
        a.add("444");
        Iterator<String>i=a.iterator();
        while (i.hasNext()){
            String o=i.next();
            System.out.println(o);
        }

















    }
}
